import host from './host'

const hostUrl = host.hostUrl;

const API = {
  //登录（y验证码）
  login: hostUrl + '/user/login',
  // 账户密码登陆
  loginAccountOrPhone: hostUrl + '/user/loginAccountOrPhone',
  //修改密码
  updatePassword: hostUrl + '/user/updatePassword',
  //修改用户信息
  updateUserInfo: hostUrl + '/user/updateUserInfo',
  //获取用户信息
  getUserInfo: hostUrl + '/user/getUserInfo',
  //  扫码获取用户信息
  getUserByOpenId: hostUrl+ '/user/getUserByOpenId',
  //发送短信验证码
  sendLoginSms: hostUrl + '/user/sendLoginSms',
  //发送短信验证码
  sendSmsForOpportunity: hostUrl + '/user/sendSmsForOpportunity',
  //我的设备列表
  listMyDevice: hostUrl + '/listMyDevice',
  //我的组织架构
  listMyOrgStruct: hostUrl + '/listMyOrgStructV02',
  //获取某个部门的设备
  listDevice: hostUrl + '/listDevice',
  //获取某个设备的参数
  getDeviceDetail: hostUrl + '/getDeviceDetail',
    //获取某个设备的参数
  getDeviceDetails: hostUrl + '/getDeviceDetails',
  //获取我的巡检历史
  listMyCheckRecord: hostUrl + '/listMyCheckRecord',
  //获取某天某设备的巡检记录
  listCheckRecordByDate: hostUrl + '/listCheckRecordByDate',
  //获取设备的部件列表
  listDeviceComponent: hostUrl + '/listDeviceComponent',
  //获取设备部件更换记录
  listReplaceRecordByDeviceId: hostUrl + '/listReplaceRecordByDeviceId',
  //获取部件的更换记录
  listReplaceRecordByComponentId: hostUrl + '/listReplaceRecordByComponentId',
  //一键更换
  onekeyReplace: hostUrl + '/onekeyReplace',
  //获取微信配置
  getWxConfig: hostUrl + '/wxAuth/getWxConfig',
  //公众号授权
  getWxCode: hostUrl + '/wxAuth/getWxCode',
  //上传图片
  upload: hostUrl + '/file/upload',
  //添加巡检记录
  addCheckRecord: hostUrl + '/addCheckRecord',
  //添加更换记录
  addReplaceRecord: hostUrl + '/addReplaceRecord',
  //保存商机
  saveOpportunity: hostUrl + '/opportunity/saveOpportunity',
  //入库管理-部件列表-入库
  inventList:hostUrl + '/componentList',
  //入库管理-部件详情
  inventDetail:hostUrl + '/componentDetails',
  //入库管理-部件列表
  inventItem:hostUrl+'/stockComponentList',
  //部件延后更换
  delayedReplace: hostUrl + '/delayedReplace',
  // 设备延后更换
  delayedDeviceReplace: hostUrl + '/delayedDeviceReplace',
  // 获取部件更换截止日期
  delayedReplaceDate : hostUrl + '/delayedReplaceDate',
  // 获取设备延后更换日期
  delayedDeviceReplaceDate : hostUrl + '/delayedDeviceReplaceDate',
  //获取设备组件列表
  checkRecordList: hostUrl + '/checkRecordList',
  //部件巡检
  checkComponent: hostUrl + '/checkComponent',
  //删除图片
  deleteCheckImg: hostUrl + '/delImage',
  //退出登录
  logout: hostUrl + '/user/logout',
  //获取规格
  getCategoryList: hostUrl + '/stockCategoryList',
  //入库
  saveStockOperator: hostUrl + '/stockOperator',
  // 获取设备点巡检
  loadDeviceCheckRecord: hostUrl + '/checkConfig/loadCheckRecords',
  //获取设备点巡检设置列表
  deviceCheckRecordList: hostUrl + '/deviceCheckRecordList',
  // 获取未点巡检数量
  getCheckConfigNum: hostUrl + '/checkRecord/count',
  // 运维首页-点巡检-个人可执行
  getCheckRecordProcessingByUser: hostUrl + '/checkRecord/processingByUser',
  // 运维首页-更换-可执行
  getReplaceRecordByUser: hostUrl + '/replaceRecord/processing',
  // 运维首页-更换-历史记录
  getReplaceRecordHandle: hostUrl + '/replaceRecord/handle',
  // 获取设备下所有部件点巡检记录1
  // loadComponentCheckRecord: hostUrl + '/checkRecord/loadCheckRecords',
  loadComponentCheckRecord: hostUrl + '/checkRecord/loadComponentCheckRecords',
  // 获取部门下所有设备点巡检记录
  loadDeviceCheckRecords: hostUrl + '/checkRecord/loadDeviceCheckRecords',
  // 获取用户部门所有领导(上报人)
  getLeader: hostUrl + '/user/getLeaders',
  // 添加设备点巡检记录
  addDeviceCheckRecord: hostUrl + '/addDeviceCheckRecord',

  // 获取设备点巡检记录（判断是否可操作 2020-02-05）
  deviceCheckRecordById: hostUrl + '/checkRecord/loadDeviceCheckRecordById',

  // 获取部件点巡检记录（判断是否可操作 2020-02-05）
  componentCheckRecordById: hostUrl + '/checkRecord/loadComponentCheckRecordById',

  // 获取该设备所有的点巡检记录2
  // loadDeviceCheckRecordByDeviceId: hostUrl + '/checkRecord/loadAllDeviceRecords',
  loadDeviceCheckRecordByDeviceId: hostUrl + '/checkRecord/loadDeviceCheckRecordBydeviceId',
  // 查询点巡检记录详情
  loadCheckDetail: hostUrl + "/checkRecord/loadRecordDetails",
  // 查询部门下所有设备
  loadDeviceList: hostUrl + '/device/getDeviceInfo',
  //获取设备管理首页信息
  getDeviceNum: hostUrl + '/device/getDeviceNum',
  //微信验证信息
  getWxSign: hostUrl + '/wxAuth/getWxSign',
  //获取首页信息
  getAgencyMatters: hostUrl + '/user/getAgencyMatters',
  //获取设备列表信息
  getDeviceList: hostUrl + '/device/getDeviceList',
  //组织架构
  loadOrganStructure: hostUrl + '/user/loadOrganStructure',
  // 获取部门下所有设备的更换设置
  loadDeviceReplaceConfig: hostUrl + '/getDeviceReplaceConfig',
  // 获取设备待更换设备数量
  getReplaceRecordCount: hostUrl + '/replaceRecord/count',
  // 添加设备更换记录
  addDeviceReplace: hostUrl + '/addDeviceReplaceRecord',
  // 设备下所有部件的更换设置
  loadComponentReplaceConfig: hostUrl + '/getComponnentReplaceRecord',
  // 部门下所有设备的更换记录
  loadDeviceReplaceRecord: hostUrl + '/loadAllDeviceReplaceRecord',
  // 设备所有更换记录
  loadDeviceAllReplaceRecord: hostUrl + '/getDeviceReplaceRecordDetails',
// 设备下所有部件的添加更换记录
  loadCompReplaceRecord: hostUrl + '/getCompReplaceRecordDetails',

  // 部门下工单各种类型数量统计总数
  getAllManagerNum: hostUrl + "/workSheet/allManagerNum",
  // 部门下工单各种类型数量统计
  workSheetInfo: hostUrl + "/workSheet/queryUserLeader",
  // 部门下未处理工单总数
  getUnHandleManagerNum: hostUrl + "/workSheet/userStatistics",
   // 部门下未处理工单
   loadToDealWorkSheet: hostUrl + "/workSheet/unHandleManager",
  // 我提交的工单总数
  getSubmitManagerNum: hostUrl + "/workSheet/submitManagerNum",
  // 我完结的工单总数
  getHandleManagerNum: hostUrl + '/workSheet/handleManagerNum',
  // 我提交的工单列表
  mySubmitWorkSheets: hostUrl + "/workSheet/submitManager",
  // 我完结的工单列表
  myFinishedWorkSheets: hostUrl + '/workSheet/handleManager',
  // 历史工单
  loadHistoryWorkSheet: hostUrl + '/workSheet/historyWorkSheet',
  // 工单处理过程详情
  // getWorkSheetPeocessInfo: hostUrl + '/workSheet/getWorkSheetHandleInfo',
  // 获取工单信息
  getWorkSheetInfo: hostUrl + '/workSheet/getWorkSheetInfo',
  // 工单评论详情
  // getWorkSheetCommentDetails: hostUrl + '/workSheet/commentsDetail',
  // 工单评论权限
  // authWorkSheetComment: hostUrl + '/workSheet/accessComment',
  // 添加工单评论
  // addWorkSheetComment: hostUrl + '/workSheet/saveComment',
  // 获取转办人
  loadTransferees: hostUrl + '/user/loadUserByDepart',
  // 添加工单记录
  // addWorkSheetRecord: hostUrl + '/workSheetHandle/save',
  // 我回复的工单
  loadMyWorkSheet: hostUrl + '/workSheet/getMyWorkSheet',
  // //点巡检记录-部件点巡检记录
  // loadComponentCheckRecords: hostUrl + '/checkConfig/loadComponentCheckRecords',
  //运维工单首页信息
  getCheckRecordByMonth: hostUrl + '/checkRecord/countLastWeekAboutCheck',
    // 部门下所有异常工单
  loadExceptionWorkSheet: hostUrl + '/workSheet/getExecWorkSheet',
  // 异常工单的处理记录
  loadExceptWorkSheetRecord: hostUrl + '/workSheetHandle/getExecWorkSheetHandle',
  // 提交异常工单提醒记录
  addExceptWorkSheetRecord: hostUrl + '/workSheet/saveLeapfrogRemind',
  //扫码之后获取的设备信息
  loadDeviceInfo: hostUrl + '/loadDeviceInfo',
  //扫码之后获取的设备更换信息
  getDeviceReplaceConfigByDeviceId: hostUrl + '/getDeviceReplaceConfigByDeviceId',
  // 获取部门下所有异常工单
  loadExecWorkSheet: hostUrl + '/workSheet/getExecWorkSheet',
  // 查询部门所有人员信息
  searchPerson: hostUrl + '/user/loadByNameOrDepart' ,
  // 获取统计点巡检数据
  getCheckMatters: hostUrl + '/user/getCheckMatters',
  // 获取统计更换数据
  getReplaceMatters: hostUrl + '/user/getReplaceMatters',
  // 获取工单统计数据
  getWorkSheetMatters: hostUrl + '/user/getWorkSheetMatters',
  // 获取设备详细信息
  getDeviceDetail: hostUrl + '/device/getDeviceInfo',
  // 获取点巡检工单详情
  getCheckWorkSheet: hostUrl + '/workSheetHandle/loadWorkSheetHandleByCheckId',
  // 获取更换记录近七天的数量统计
  getReplaceRecordByMonth: hostUrl + '/checkRecord/countLastWeekAboutReplace',
  // 设备点巡检记录统计数量
  getDeviceCheckRecordNum: hostUrl + '/checkRecord/loadDeviceCheckRecordCount',
  // 设备更换记录数量统计
  getDeviceReplaceRecordNum: hostUrl + '/loadDeviceReplaceRecordCount',
  // 获取登录人组织架构
  getMyOrganization: hostUrl + '/listMyOrgStructV03',
  // 获取当前部门的层级关系
  getDepartmentStruct:  hostUrl + '/getDepartmentParentId',
  // 获取设备信息的模版编码
  getDeviceCode:  hostUrl + '/device/getDeviceMonitor',
  // 获取设备信息的模版编码
  getRunList:  hostUrl + '/device/listDeviceRunRecord',
  //查询部门的负责人
  getDepartmentCharger: hostUrl + '/user/loadDepartmentLeader',
  //筛选状态条件获取
  getScheduleStatus: hostUrl + '/getScheduleStatus',
  //获取点巡检中设备列表数据
  // deviceWaitCheckRecordList: hostUrl + '/deviceWaitCheckRecordList',
  //获取设备点巡检部件列表数据
  checkDeviceRecordList: hostUrl + '/checkDeviceRecordList',
  //获取点巡检列表数据

  // 获取部门下所有部门和员工
  listDepartmentUser: hostUrl + '/listDepartmentUser',
  getLoadDeviceAndComponentConfig: hostUrl + '/checkRecord/loadDeviceAndComponentConfig',
  //点击待执行列表查询设备列表
  getCheckWaitRecordList: hostUrl + '/checkWaitRecordList',
  //点击待执行列表查询部件列表
  getCheckWaitDeviceRecordList: hostUrl + '/checkWaitDeviceRecordList',

  //设备管理部门列表(带各个企业的各个设备运行状态数量)
  getDeviceOrgNumList: hostUrl + '/device/deviceStatistic',

  // 部件点巡检转办
  tansferCompCheck: hostUrl + '/transferComponentCheckRecord',

  // 设备点巡检转办
  transferDevCheck: hostUrl + '/transferDeviceCheckRecord',

  // 可执行一键转办
  transferAllCheck: hostUrl + '/transferAllCheckRecord',
  // 待执行一键转办
  transferAllWaitCheck: hostUrl + '/transferAllWaitCheckRecord',
  //获取点巡检中待执行列表数据
  deviceWaitCheckRecordList: hostUrl + '/deviceWaitCheckRecordList',
  //获取点巡检中已完成列表数据
  checkRecordHandleList: hostUrl + '/checkRecord/handle',
  //获取点巡检中已逾期列表数据
  checkRecordOverTimeList: hostUrl + '/checkRecord/overTime',
  //获取设备点巡检部件列表数据
  checkDeviceRecordList: hostUrl + '/checkDeviceRecordList',
  //获取更换设置列表数据
  replaceSetRecordList: hostUrl + '/replaceConfig/load',

  // 获取部门下所有部门和员工
  listDepartmentUser: hostUrl + '/listDepartmentUser',
  getLoadDeviceAndComponentConfig: hostUrl + '/checkRecord/loadDeviceAndComponentConfig',
  //点击待执行列表查询设备列表
  getCheckWaitRecordList: hostUrl + '/checkWaitRecordList',
  //点击待执行列表查询部件列表
  getCheckWaitDeviceRecordList: hostUrl + '/checkWaitDeviceRecordList',

  //设备管理部门列表(带各个企业的各个设备运行状态数量)
  getDeviceOrgNumList: hostUrl + '/device/deviceStatistic',
  
  //部门负责人
  getLoadLeader: hostUrl + '/user/loadLeader',
  //部门负责人（新，2020-1-14）
  getLoadAllUser: hostUrl + '/user/loadAllUser',
  //转办负责人（新，2020-1-15）
  getLoadTransposeUser: hostUrl + '/user/loadTransposeUser',
  // 设备详情逾期列表
  checkDeviceOverdueRecordList: hostUrl + '/checkDeviceOverdueRecordList',
  // 设备详情部件逾期列表
  checkOverdueRecordList: hostUrl + '/checkOverdueRecordList',

  loadScreen: hostUrl + '/workSheet/screen',

  // 部件点巡检转办
  tansferCompCheck: hostUrl + '/transferComponentCheckRecord',

  // 设备点巡检转办
  transferDevCheck: hostUrl + '/transferDeviceCheckRecord',

  // 可执行一键转办
  transferAllCheck: hostUrl + '/transferAllCheckRecord',
  // 待执行一键转办
  transferAllWaitCheck: hostUrl + '/transferAllWaitCheckRecord',

  // 获取负责人
  getPeople:hostUrl + "/loadUserByDepartment",

  // 获取所有设备
  getAllDevice:hostUrl + "/device/loadByDepartment",

  // 获取部件
  getAllParts:hostUrl + "/device/loadComponent",

  // 点击提交
  // referTo:hostUrl + "/workSheet/save",

  // 服务区域下处理中工单数量
  getCountByDepartment: hostUrl + '/workSheet/processingCountByDepartment',
  // 个人处理中工单数量
  getCountByUser: hostUrl + '/workSheet/processingCountByUser',
  // 服务区域下已处理工单数量
  getByDepartment: hostUrl + '/workSheet/handledCountByDepartment',
  // 个人已处理工单数量
  handledCountByUser: hostUrl + '/workSheet/handledCountByUser',
  // 服务区域下超时工单数量
  getoverTimeCount: hostUrl + '/workSheet/overTimeCountByDepartment',
  // 个人超时工单数量
  overTimeCountByUser: hostUrl + '/workSheet/overTimeCountByUser',
  // 待处理
  getprocessing: hostUrl + '/workSheet/processing',
  // 已处理工单
  gethandled: hostUrl + '/workSheet/queryUserLeader',

  // 获取所有设备
  getAllDevice:hostUrl + "/device/loadByDepartment",

  // 获取部件
  getAllParts:hostUrl + "/device/loadComponent",

  // 点击提交

  // referTo:hostUrl + "/workSheet/save",
  // 部分权限认证
  getDepartment:hostUrl + "/user/isLeader",
  // 我提交
  submitByUser:hostUrl + "/workSheet/submitByUser",
  // 我的工单
  myWorkSheets:hostUrl + "/workSheet/queryUserSubmit",

  //设备详情页时长统计
  duringTimeStatistics: hostUrl +"/device/duringTimeStatistics",
  //设备详情页次数统计
  happenTimesStatistics: hostUrl +"/device/happenTimesStatistics",
  //获取所属区域的点巡检统计
  checkCountOperatemanagerHomepage: hostUrl +"/checkTaskRecord/countOperatemanagerHomepage",
  //运维管理点巡检图表统计
  getCheckByDay:hostUrl+'/checkTaskRecord/countByDay',
  //运维管理点巡检列表
  getCheckList:hostUrl+'/checkTaskRecord/query',
  //根据ID获取点巡检任务详情接口
  getcheckTaskdetail: hostUrl+'/checkTaskRecord/detail',
  //提交点巡检任务接口
  getcheckTaskSubmit: hostUrl+'/checkTaskRecord/submit',
  //点巡检转办
  checkTransForm: hostUrl+'/checkTaskRecord/transform',
  //获取点巡检设置列表数据
  checkSetRecordList: hostUrl + '/checkTaskConfig/query',
  // 扫码获取点巡检列表
  scancodeQueryCheckList: hostUrl + '/checkTaskRecord/scancodeQuery',
  scancodeQueryCheckList: hostUrl + '/checkTaskRecord/scancodeQuery',
  delayHandleCountByDepartment: hostUrl + '/workSheet/delayHandleCountByDepartment',
  delayHandleCountByUser: hostUrl + '/workSheet/delayHandleCountByUser'

}



export default API;
